//
//  YWInspectionMissionModel.h
//  maintain
//
//  Created by Kyo on 16/5/25.
//  Copyright © 2016年 ewin. All rights reserved.
//

#import <Foundation/Foundation.h>
@class YWHandler;
@class YWInspectionLineRecord;
@class YWLocation;
@class YWShortBuilding;

typedef NS_ENUM(NSInteger, YWInspectionLineType) {
    YWInspectionLineTypeEquipment = 0,//设备巡查
    YWInspectionLineTypeLocation = 1, //位置巡查
};
@interface YWInspectionLineLocationRel : NSObject
/**路线ID*/
@property (nonatomic, assign) NSInteger inspectionLineId;
/**位置排序数字*/
@property (nonatomic, assign) NSInteger sort;
/**位置Id*/
@property (nonatomic, assign) NSInteger locationId;
/**位置对象*/
@property (nonatomic, strong) YWLocation* location;
/**线路要求*/
@property (nonatomic, copy) NSString *note;
@end

@interface YWInspectionLineWeekRel : NSObject
/**路线ID*/
@property (nonatomic, assign) NSInteger inspectionLineId;
/**星期几	0：周天，1-6：周一至周六*/
@property (nonatomic, assign) NSInteger week;
@end

@interface YWInspectionLineModel : NSObject
/**线路ID*/
@property (nonatomic, assign) NSInteger inspectionLineId;
/**线路名称*/
@property (nonatomic, copy) NSString *inspectionLineName;
/**线路类型*/
@property (nonatomic, assign) YWInspectionLineType lineType;
/**间隔时间（单位分钟）*/
@property (nonatomic, assign) NSInteger intervalMinute;
/**线路制定人*/
@property (nonatomic, strong) YWHandler *creator;
/**路线创建时间*/
@property (nonatomic, assign) NSTimeInterval createTime;
/**路线更新或者叫修改时间*/
@property (nonatomic, assign) NSTimeInterval updateTime;
/**线路状态（0正常-1删除）*/
@property (nonatomic, assign) NSInteger status;
/**线路要求*/
@property (nonatomic, copy) NSString *note;
/**巡查设备集合*/
@property (nonatomic, strong) NSArray *equipments;
/**巡查位置点*/
@property (nonatomic, strong) NSArray* locationRels;
/**巡更每周循环天*/
@property (nonatomic, strong) NSArray* weekRels;
@end

@interface YWInspectionMissionModel : NSObject
/**设备巡查任务ID*/
@property (nonatomic, assign) NSInteger inspectionMissionId;
/**楼盘ID*/
@property (nonatomic, copy) NSString *buildingId;
/**楼盘对象*/
@property (nonatomic, strong) YWShortBuilding *building;
/**任务名*/
@property (nonatomic, copy) NSString *inspectionMissionName;
/**任务编号*/
@property (nonatomic, copy) NSString *missionSequence;
/**任务创建时间*/
@property (nonatomic, assign) NSTimeInterval createTime;
/**任务状态（0正常-1删除,-2是请求与我相关的巡查记录接口返回的不完整的任务）*/
@property (nonatomic, assign) NSInteger status;
/**巡查路线*/
@property (nonatomic, strong) YWInspectionLineModel *inspectionLine;
/**任务制定人*/
@property (nonatomic, strong) YWHandler *creator;
/**任务执行人数组*/
@property (nonatomic, strong) NSArray *executors;
/**任务开始日期*/
@property (nonatomic, assign) NSTimeInterval startDate;
/**任务截止日期*/
@property (nonatomic, assign) NSTimeInterval endDate;
/**任务开始时间*/
@property (nonatomic, copy) NSString *startTime;
/**任务结束时间*/
@property (nonatomic, copy) NSString *endTime;

/**@的人集合*/
@property (nonatomic, strong) NSArray *observers;
/**@的人的id串*/
@property (nonatomic, copy) NSString *observerIds;

/**当前巡查时间区段，不解析(用于cell，取数据时获取，避免cell显示时费时操作)*/
@property (nonatomic, strong) NSArray *currentLooperTimeArray;
/**当前巡查区段的uniqueTag*/
@property (nonatomic, copy) NSString *uniqueTag;
@end

@interface YWInspectionLineOption : NSObject
/**线路ID*/
@property (nonatomic, assign) NSInteger inspectionLineId;
/**线路名称*/
@property (nonatomic, copy) NSString *inspectionLineName;
@end
